Set up Flutter
Dinglun Alex Zhou 2020-09-21 flutter
# Before install
- go to BIOS check if CPU virtualisation is enabled
- if not enabled, enable it and restart
For Linux check the following tools:
Tools: Flutter depends on these command-line tools being available in your environment.
bashcurlfilegit2.xmkdirrmunzipwhichxz-utilszip
# Install
# Windows
use
gitC:\src>git clone https://github.com/flutter/flutter.git -b stable1From the Start search bar, enter ‘env’ and select Edit environment variables for your account.
Under User variables check if there is an entry called
Path:
- If the entry exists, append the full path to
flutter\binusing;as a separator from existing values. - If the entry doesn’t exist, create a new user variable named
Pathwith the full path toflutter\binas its value.
- If the entry exists, append the full path to
# Linux
install from
snap:sudo snap install flutter --classic1without snap:
- install from
git
cd ~/src git clone https://github.com/flutter/flutter.git1
2- add the
PATHto the shell rc such like:.zshrc
export PATH="$PATH:/home/zhoudl0605/src/flutter/bin"1- Check is install success
which flutter1- install from
# After install
- install Android Studio
- install SDK from Android Studio and create the AVD
- run
flutter doctorto set up